package com.eddie.strategy.improve;


/**
 * @author Eddie
 * @date 2022/08/08 13:49
 **/
public class ToyDuck extends Duck {


    public ToyDuck() {
        super.setFlyBehavior(new NoFlyBehavior());
    }

    @Override
    public void display() {
        System.out.println("~~~~~玩具鸭~~~~~");
    }

    @Override
    public void quack() {
        System.out.println("玩具鸭不能叫");
    }

    @Override
    public void swim() {
        System.out.println("玩具鸭不会游泳");
    }
}
